package com.example.blog.demos.web.model;

import com.example.blog.demos.web.utils.DateUtils;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import java.util.Date;

/**
 * @author Q
 * @create 2025-06-19-9:04
 */
@Data
public class BlogInfo {
    private Integer id;
    @NotBlank(message = "title不能为空")
    private String title;
    @NotBlank(message = "content 不能为空")
    private String content;

    private Integer userId;
    private Integer deleteFlag;
    //当前作者是否为登录用户
    private Boolean isLoginUser;

    private Date createTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date updateTime;
}
